﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ServiceModel;
using Bankeren.Engine;
using Bankeren.Engine.Cards;

namespace Bankeren.Service
{
    [ServiceContract(CallbackContract = typeof(IBankerenCallback), SessionMode = SessionMode.Required)]
    [DeliveryRequirements(RequireOrderedDelivery = true)]
    public interface IBankeren
    {
        [OperationContract(IsInitiating = true)]
        bool Join(PlayerInfo info);
        [OperationContract(IsInitiating = false, IsOneWay = true)]
        void ChangeInfo(PlayerInfo info);
        [OperationContract(IsInitiating = false, IsOneWay = true)]
        void MakeBid(int bid);
        [OperationContract(IsInitiating = false)]
        bool PlayCard(Card card);
        [OperationContract(IsInitiating = false, IsOneWay = true)]
        void BroadcastChat(string message);
        [OperationContract(IsInitiating = false, IsOneWay = true, IsTerminating = true)]
        void Leave();
    }
}
